<template>
	<uni-transition :show="show" :duration="400">
		<view class="empty">
			<view class="hd">
				<image src="/static/empty.png" mode="widthFix"></image>
			</view>
			<view class="bd">
				<view class="txt">{{msg}}</view>
			</view>
		</view>
	</uni-transition>
</template>
<script setup>
	import { ref, onMounted } from 'vue';
	const show = ref(false);
	onMounted(() => {
		show.value = true;
	})
	defineProps({
		msg: {
			type: String,
			default: '暂无数据'
		},
		padding: {
			type: String,
			default: '100rpx 0'
		}
	})
</script>
<style scoped lang="scss">
	.empty {
		padding: v-bind(padding);
		text-align: center;
		.hd {
			image {
				width: 160rpx;
			}
		}
		.bd {
			.txt {
				padding-right: 10rpx;
				line-height: 46rpx;
				font-size: 28rpx;
				color: #999;
			}
		}
	}
</style>
